package com.qf.util;

import com.qf.handler.RoleException;
import com.qf.vo.ResultVO;

public class ResultVOUtil {

    public static ResultVO success(Object data){
        return new ResultVO(0,"成功",data);
    }

    public static ResultVO success(){
        return ResultVOUtil.success(null);
    }

    public static ResultVO error(RoleException ex){
        return new ResultVO(ex.getCode(),ex.getMessage(),null);
    }
}
